<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"  prefix="c"%>
<!-- f标签 取得jsp一些函数工具 -->
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="f"%>
<!-- 格式化标签 -->
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
 <% String path = request.getContextPath();%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
	<form>
		姓名:<input type="text" name="uname" id="aaa" value="${user.uname}"><br>

		性别:<input type="radio" name="sex"  value="1" <c:if test="${user.sex == 1}">checked</c:if>>男
		<input type="radio" name="sex" value="2" <c:if test="${user.sex == 2}">checked</c:if>>女<br>

		生日:<input type="Date" name="birth" id="birth"value="<fmt:formatDate value="${user.birth}" pattern="yyyy-MM-dd"/>"><br>

		部门:<select id="bbb">
		<option value="-1">部门选择</option>
		<c:forEach items="${tDeps}" var="dep">
			<option value="${dep.depId}" <c:if test="${dep.depId == user.depId}">selected</c:if>>${dep.depName}</option>
		</c:forEach>
		</select><br>

		角色:
		<c:forEach items="${roles }" var="roles">
			<input type="checkbox" name="rid" value="${roles.rid}" <c:if test="${role.contains(roles.rid)}">checked</c:if>> ${roles.rname}
		</c:forEach>
	</form>
</body>
</html>